solve k*l+m=365 and k+l=77 and k>0,m>0,l>0 in integers